dnd: Add some warnings to the docs
authorMatthias Clasen <mclasen@redhat.com>
Tue, 16 Mar 2021 18:24:04 +0000 (14:24 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Tue, 16 Mar 2021 18:48:44 +0000 (14:48 -0400)
Add some warnings about pitfalls of the async dnd api.

gdk/gdkdrop.c

index 4d7ab014f3a6f1c58fb3c6b2c0691520ef0c0af0..cb1cdb1bf68c017b25244347c57c63fdbf3c07ba 100644 (file)
@@ -699,6 +699,11 @@ gdk_drop_read_async (GdkDrop             *self,
  *
  * Finishes an async drop read operation.
  *
+ * Note that you must not use blocking read calls on the returned stream
+ * in the GTK thread, since some platforms might require communication with
+ * GTK to complete the data transfer. You can use async APIs such as
+ * g_input_stream_read_bytes_async().
+ *
  * See [method@Gdk.Drop.read_async].
  *
  * Returns: (nullable) (transfer full): the `GInputStream`, or %NULL